/**
 *
 */

"use strict";

//=========================
// 引入子组建和子组建reducer
//=========================


export const  DEMAND_LIST = "DEMAND_LIST";

export const MobileDemandReducers = (state = [],action) => {
    switch (action.type) {
        case DEMAND_LIST:
            state = action.data;
        default :
            return state;
    }
};

export const mapStateToProps = state =>{
    return {
        demandList  :  state.app.demandList  ? state.app.demandList : []
    }
} ;

export const mapDispatchToProps = dispatch =>{
    return{
        initialDemand: (e) => {
            dispatch({type: DEMAND_LIST, data: e})
        }
    }
} ;

